package com.abc.service.impl;

import com.abc.entity.DailyRecord;
import com.abc.mapper.DailyRecordMapper;
import com.abc.service.IDailyRecordService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.time.LocalDateTime;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author
 * @since 2024-12-25
 */
@Service
public class DailyRecordServiceImpl extends ServiceImpl<DailyRecordMapper, DailyRecord> implements IDailyRecordService {
    @Override
    public boolean addLog(DailyRecord dailyRecord, Long userId) {
        dailyRecord.setUserId(userId);
        dailyRecord.setStatus("存在");
        dailyRecord.setGmtCreate(LocalDateTime.now());
        return this.save(dailyRecord);
    }
}
